package com.akl.ssmspringboot.service.impl;

import com.akl.ssmspringboot.dao.LoginMapper;
import com.akl.ssmspringboot.entity.Login;
import com.akl.ssmspringboot.service.LoginService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @ClassName:
 * @Author: Guoxy
 * @Date: Created in 16:44 2018/11/30
 * @Version:1.0
 */
@Service
public class LoginServiceImpl extends ServiceImpl<LoginMapper, Login> implements LoginService {

    @Resource
    private LoginMapper loginMapper;

    @Override
    public Boolean checkLogin(String loginName, String password) {
        Login login = loginMapper.selectLogin(loginName, password);
        Boolean result = true;
        if(login == null){
            result = false;
        }
        return result;
    }

}
